package de.tum.in.eist.im.client.Chat;

// import java.util.List;

import com.google.gwt.user.client.rpc.AsyncCallback;

import de.tum.in.eist.im.shared.ChatChannel.ChatChannel;
import de.tum.in.eist.im.shared.User.User;

/**
 * The async counterpart of <code>ChatPanelService</code>.
 */
public interface ChatPanelServiceAsync {
	
	// get the id of a channel with a given title
	void getChatChannelId(String channelTitle, AsyncCallback<Long> callback);
	void getPrivateChatChannelId(User thisUser, User otherUser, AsyncCallback<Long> callback);
	
	// add a user to the list of all! online users
	void addUserAsOnline(User user, AsyncCallback<Boolean> callback);
	void removeUserAsOnline(User user, AsyncCallback<Boolean> callback);
	void getOnlineUsersFromServerAsString(AsyncCallback<String> callback);
	
	// add a group to the list of all! open groups
	void addGroupAsOpen(ChatChannel chatChannel, AsyncCallback<Boolean> callback);
	void addPrivateGroupAsOpen(ChatChannel chatChannel, AsyncCallback<Boolean> callback);
	void removeGroupAsOpen(ChatChannel chatChannel, AsyncCallback<Boolean> callback);
	void getApiToken(String username, AsyncCallback<String> callback);
	void getOnlineGroupsFromServerAsString(AsyncCallback<String> callback);
}
